import Login from './views/Login.vue'
import NotFound from './views/404.vue'
import Home from './views/Home.vue'
import Main from './views/Main.vue'
import Table from './views/nav1/Table.vue'
import Form from './views/nav1/Form.vue'
import user from './views/nav1/user.vue'
import Page4 from './views/nav2/Page4.vue'
import Page5 from './views/nav2/Page5.vue'
import Page6 from './views/nav3/Page6.vue'
import echarts from './views/charts/echarts.vue'
//============组织机构==============//
import Department from './views/org/department.vue'
import Employee from './views/org/employee.vue'
//==================系统管理=========================//
import Config from './views/sys/config.vue'
import Dictionary from './views/sys/dictionary.vue'
import Dictionaryitem from './views/sys/dictionaryitem.vue'
//==================产品管理=========================//
import Product_type from './views/product/product_type.vue'
import Product from './views/product/product.vue'
//==================营销管理=========================//
import Clue from './views/mkt/clue.vue'
import Activity from './views/mkt/activity.vue'
import ActivityRemark from './views/mkt/activityRemark.vue'
import ClueRemark from './views/mkt/clueRemark.vue'
import Business from './views/mkt/business.vue'
let routes = [
    {
        path: '/login',
        component: Login,
        name: '',
        hidden: true
    },
    {
        path: '/404',
        component: NotFound,
        name: '',
        hidden: true
    },
    //{ path: '/main', component: Main },
    {
        path: '/',
        component: Home,
        name: '主页',
        leaf: true,
        iconCls: 'el-icon-message',//图标样式class
        children: [
            { path: '/echarts', component: echarts, name: '主页' }
        ]

    },
    {
        path: '/',
        component: Home,
        name: '营销管理',
        iconCls: 'el-icon-present',
        children: [
            { path: '/clue', component: Clue, name: '线索管理' },
            { path: '/activity', component: Activity, name: '营销活动' },
            { path: '/activityRemark', component: ActivityRemark, name: '营销活动备注' },
            { path: '/clueRemark', component: ClueRemark, name: '线索备注' },
            { path: '/business', component: Business, name: '商机管理' },
            { path: '/j', component: Product, name: '产品管理' }
        ]
    },
    {
        path: '/',
        component: Home,
        name: '组织机构管理',
        iconCls: 'fa fa-id-card-o',
        children: [
            { path: '/departement', component: Department, name: '部门管理' },
            { path: '/employee', component: Employee, name: '员工管理' }
        ]
    },
    {
        path: '/',
        component: Home,
        name: '系统管理',
        iconCls: 'fa fa-bar-chart',
        children: [
            { path: '/config', component: Config, name: '配置管理' },
            { path: '/dictionary', component: Dictionary, name: '数据字典' },
            { path: '/dictionaritem', component: Dictionaryitem, name: '数据字典明细' }
        ]
    },
    {
        path: '/',
        component: Home,
        name: '产品模块',
        iconCls: 'el-icon-goods ',
        children: [
            { path: '/product', component: Product, name: '产品管理' },
            { path: '/productType', component: Product_type, name: '产品类型' }
        ]
    },
    {
        path: '*',
        hidden: true,
        redirect: { path: '/404' }
    }
];

export default routes;
